﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Reflection;

namespace Kollektiv.Extension
{
    public static class System_Type
    {
        public static MethodInfo GetMethodExtended(this Type type, string methodName)
        {
            return type.GetMethod(methodName, BindingFlags.Instance | BindingFlags.Public | BindingFlags.NonPublic | BindingFlags.Static) ??
                (type.BaseType != null ? type.BaseType.GetMethodExtended(methodName) : null);
        }
    }
}
